﻿using System;
using System.Windows.Forms;
using dbcntn;

namespace Campus.Main.Basic
{
    public partial class FormCity : Form
    {
        private ConnectionToDb ob;
        public FormCity()
        {
            InitializeComponent();
            ob=new ConnectionToDb(Helper.ConnectionString);
        }

        private void button1_Click(object sender, EventArgs e)
        {
            if (textBox1.Text.Length>0)
            {
                ob.InsertIntoTable("city","country_id","city_name",Convert.ToInt32(comboBox1.SelectedValue),textBox1.Text);
            }
        }
    }
}
